import React from 'react';
import { Provider } from 'react-redux'
import { browserHistory } from 'react-router';
import { storiesOf, action } from '@kadira/storybook';
import { muiTheme } from 'storybook-addon-material-ui';
import configureStore from '../../stores/configureStore';
import Report from './Report';
import 'normalize.css';
import '../../App.css';
/*global module*/

const store = configureStore(browserHistory);

storiesOf('結果表示 (全体)', module)
  .addDecorator(muiTheme())
  .addDecorator(getStory => (
    <Provider store={store}>
      {getStory()}
    </Provider>
  ))
  .add('to 結果表示 (男性)', () => (
    <Report
      inputData={{
        gender: 1,
      }}
      fiveHealthHabit={{
        you: 0.004,
        ave: 0.005,
        min: 0.001,
        max: 0.02,
        riskLevel: 'HIGH',
      }}
      cerebralStroke={{
        you: 0.015,
        ave: 0.005,
        min: 0.001,
        max: 0.02,
        riskLevel: 'A_LITTLE_HIGH',
      }}
      cardiacInfarction={{
        you: 0.005,
        ave: 0.005,
        min: 0.001,
        max: 0.02,
        riskLevel: 'LOW',
      }}
      gastricCancer={{
        you: 0.002,
        ave: 0.005,
        min: 0.001,
        max: 0.02,
        riskLevel: 'A_LITTLE_HIGH',
      }}
      colorectalCancer={{
        you: 0.008,
        ave: 0.005,
        min: 0.001,
        max: 0.02,
        riskLevel: 'HIGH',
      }}
      onAction={action('確定')}
      onCancel={action('キャンセル')}
    />
  ))
  .add('to 結果表示 (女性)', () => (
    <Report
      inputData={{
        gender: 2,
      }}
      fiveHealthHabit={{
        you: 0.011,
        ave: 0.005,
        min: 0.001,
        max: 0.02,
        riskLevel: 'HIGH',
      }}
      cerebralStroke={{
        you: 0.006,
        ave: 0.005,
        min: 0.001,
        max: 0.02,
        riskLevel: 'A_LITTLE_HIGH',
      }}
      cardiacInfarction={{
        you: 0.007,
        ave: 0.005,
        min: 0.001,
        max: 0.02,
        riskLevel: 'LOW',
      }}
      gastricCancer={{
        you: 0.001,
        ave: 0.005,
        min: 0.001,
        max: 0.02,
        riskLevel: 'A_LITTLE_HIGH',
      }}
      onAction={action('確定')}
      onCancel={action('キャンセル')}
    />
  ));
